<?php

use Illuminate\Support\Facades\Schema;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Database\Migrations\Migration;

class CreateLinksTable extends Migration
{
    //提交
    public function up()
    {
        Schema::create('links', function (Blueprint $table) {
            $table->increments('id');
            $table->string('name')->comment('网站名称');
            $table->string('url')->comment('网站网址');
            $table->string('thumb')->default('')->comment('缩略图|image');
            $table->tinyInteger('show')->default(0)->comment('是否展示|1:是,0:否');
            $table->timestamps();
        });
    }

    //回滚
    public function down()
    {
        Schema::dropIfExists('links');
    }
}
